/*
 * Flowable REST API
 * # flowable / flowəb(ə)l /    - a compact and highly efficient workflow and Business Process Management (BPM) platform for developers, system admins and business users.  - a lightning fast, tried and tested BPMN 2 process engine written in Java. It is Apache 2.0 licensed open source, with a committed community.  - can run embedded in a Java application, or as a service on a server, a cluster, and in the cloud. It integrates perfectly with Spring. With a rich Java and REST API, it is the ideal engine for orchestrating human or system activities.
 *
 * OpenAPI spec version: v1
 *
 *
 * NOTE: This class is auto generated by the swagger code generator program.
 * https://github.com/swagger-api/swagger-codegen.git
 * Do not edit the class manually.
 */


package com.ibm.risk.irmp.workflow.client.flowable.model;

import java.util.Objects;
import com.fasterxml.jackson.annotation.JsonProperty;
import io.swagger.annotations.ApiModelProperty;
import java.time.OffsetDateTime;
import java.util.ArrayList;
import java.util.List;

/**
 * HistoricProcessInstanceResponse
 */

public class HistoricProcessInstanceResponse {
  @JsonProperty("id")
  private String id = null;

  @JsonProperty("url")
  private String url = null;

  @JsonProperty("name")
  private String name = null;

  @JsonProperty("businessKey")
  private String businessKey = null;

  @JsonProperty("processDefinitionId")
  private String processDefinitionId = null;

  @JsonProperty("processDefinitionUrl")
  private String processDefinitionUrl = null;

  @JsonProperty("processDefinitionName")
  private String processDefinitionName = null;

  @JsonProperty("processDefinitionDescription")
  private String processDefinitionDescription = null;

  @JsonProperty("startTime")
  private OffsetDateTime startTime = null;

  @JsonProperty("endTime")
  private OffsetDateTime endTime = null;

  @JsonProperty("durationInMillis")
  private Long durationInMillis = null;

  @JsonProperty("startUserId")
  private String startUserId = null;

  @JsonProperty("startActivityId")
  private String startActivityId = null;

  @JsonProperty("endActivityId")
  private String endActivityId = null;

  @JsonProperty("deleteReason")
  private String deleteReason = null;

  @JsonProperty("superProcessInstanceId")
  private String superProcessInstanceId = null;

  @JsonProperty("variables")
  private List<RestVariable> variables = null;

  @JsonProperty("callbackId")
  private String callbackId = null;

  @JsonProperty("callbackType")
  private String callbackType = null;

  @JsonProperty("referenceId")
  private String referenceId = null;

  @JsonProperty("referenceType")
  private String referenceType = null;

  @JsonProperty("tenantId")
  private String tenantId = null;

  public HistoricProcessInstanceResponse id(String id) {
    this.id = id;
    return this;
  }

   /**
   * Get id
   * @return id
  **/
  @ApiModelProperty(example = "5", value = "")
  public String getId() {
    return id;
  }

  public void setId(String id) {
    this.id = id;
  }

  public HistoricProcessInstanceResponse url(String url) {
    this.url = url;
    return this;
  }

   /**
   * Get url
   * @return url
  **/
  @ApiModelProperty(example = "http://localhost:8182/history/historic-process-instances/5", value = "")
  public String getUrl() {
    return url;
  }

  public void setUrl(String url) {
    this.url = url;
  }

  public HistoricProcessInstanceResponse name(String name) {
    this.name = name;
    return this;
  }

   /**
   * Get name
   * @return name
  **/
  @ApiModelProperty(example = "myProcessInstanceName", value = "")
  public String getName() {
    return name;
  }

  public void setName(String name) {
    this.name = name;
  }

  public HistoricProcessInstanceResponse businessKey(String businessKey) {
    this.businessKey = businessKey;
    return this;
  }

   /**
   * Get businessKey
   * @return businessKey
  **/
  @ApiModelProperty(example = "myKey", value = "")
  public String getBusinessKey() {
    return businessKey;
  }

  public void setBusinessKey(String businessKey) {
    this.businessKey = businessKey;
  }

  public HistoricProcessInstanceResponse processDefinitionId(String processDefinitionId) {
    this.processDefinitionId = processDefinitionId;
    return this;
  }

   /**
   * Get processDefinitionId
   * @return processDefinitionId
  **/
  @ApiModelProperty(example = "oneTaskProcess%3A1%3A4", value = "")
  public String getProcessDefinitionId() {
    return processDefinitionId;
  }

  public void setProcessDefinitionId(String processDefinitionId) {
    this.processDefinitionId = processDefinitionId;
  }

  public HistoricProcessInstanceResponse processDefinitionUrl(String processDefinitionUrl) {
    this.processDefinitionUrl = processDefinitionUrl;
    return this;
  }

   /**
   * Get processDefinitionUrl
   * @return processDefinitionUrl
  **/
  @ApiModelProperty(example = "http://localhost:8182/repository/process-definitions/oneTaskProcess%3A1%3A4", value = "")
  public String getProcessDefinitionUrl() {
    return processDefinitionUrl;
  }

  public void setProcessDefinitionUrl(String processDefinitionUrl) {
    this.processDefinitionUrl = processDefinitionUrl;
  }

  public HistoricProcessInstanceResponse processDefinitionName(String processDefinitionName) {
    this.processDefinitionName = processDefinitionName;
    return this;
  }

   /**
   * Get processDefinitionName
   * @return processDefinitionName
  **/
  @ApiModelProperty(example = "A process definition name", value = "")
  public String getProcessDefinitionName() {
    return processDefinitionName;
  }

  public void setProcessDefinitionName(String processDefinitionName) {
    this.processDefinitionName = processDefinitionName;
  }

  public HistoricProcessInstanceResponse processDefinitionDescription(String processDefinitionDescription) {
    this.processDefinitionDescription = processDefinitionDescription;
    return this;
  }

   /**
   * Get processDefinitionDescription
   * @return processDefinitionDescription
  **/
  @ApiModelProperty(example = "A process definition description", value = "")
  public String getProcessDefinitionDescription() {
    return processDefinitionDescription;
  }

  public void setProcessDefinitionDescription(String processDefinitionDescription) {
    this.processDefinitionDescription = processDefinitionDescription;
  }

  public HistoricProcessInstanceResponse startTime(OffsetDateTime startTime) {
    this.startTime = startTime;
    return this;
  }

   /**
   * Get startTime
   * @return startTime
  **/
  @ApiModelProperty(example = "2013-04-17T10:17:43.902+0000", value = "")
  public OffsetDateTime getStartTime() {
    return startTime;
  }

  public void setStartTime(OffsetDateTime startTime) {
    this.startTime = startTime;
  }

  public HistoricProcessInstanceResponse endTime(OffsetDateTime endTime) {
    this.endTime = endTime;
    return this;
  }

   /**
   * Get endTime
   * @return endTime
  **/
  @ApiModelProperty(example = "2013-04-18T14:06:32.715+0000", value = "")
  public OffsetDateTime getEndTime() {
    return endTime;
  }

  public void setEndTime(OffsetDateTime endTime) {
    this.endTime = endTime;
  }

  public HistoricProcessInstanceResponse durationInMillis(Long durationInMillis) {
    this.durationInMillis = durationInMillis;
    return this;
  }

   /**
   * Get durationInMillis
   * @return durationInMillis
  **/
  @ApiModelProperty(example = "86400056", value = "")
  public Long getDurationInMillis() {
    return durationInMillis;
  }

  public void setDurationInMillis(Long durationInMillis) {
    this.durationInMillis = durationInMillis;
  }

  public HistoricProcessInstanceResponse startUserId(String startUserId) {
    this.startUserId = startUserId;
    return this;
  }

   /**
   * Get startUserId
   * @return startUserId
  **/
  @ApiModelProperty(example = "kermit", value = "")
  public String getStartUserId() {
    return startUserId;
  }

  public void setStartUserId(String startUserId) {
    this.startUserId = startUserId;
  }

  public HistoricProcessInstanceResponse startActivityId(String startActivityId) {
    this.startActivityId = startActivityId;
    return this;
  }

   /**
   * Get startActivityId
   * @return startActivityId
  **/
  @ApiModelProperty(example = "startEvent", value = "")
  public String getStartActivityId() {
    return startActivityId;
  }

  public void setStartActivityId(String startActivityId) {
    this.startActivityId = startActivityId;
  }

  public HistoricProcessInstanceResponse endActivityId(String endActivityId) {
    this.endActivityId = endActivityId;
    return this;
  }

   /**
   * Get endActivityId
   * @return endActivityId
  **/
  @ApiModelProperty(example = "endEvent", value = "")
  public String getEndActivityId() {
    return endActivityId;
  }

  public void setEndActivityId(String endActivityId) {
    this.endActivityId = endActivityId;
  }

  public HistoricProcessInstanceResponse deleteReason(String deleteReason) {
    this.deleteReason = deleteReason;
    return this;
  }

   /**
   * Get deleteReason
   * @return deleteReason
  **/
  @ApiModelProperty(value = "")
  public String getDeleteReason() {
    return deleteReason;
  }

  public void setDeleteReason(String deleteReason) {
    this.deleteReason = deleteReason;
  }

  public HistoricProcessInstanceResponse superProcessInstanceId(String superProcessInstanceId) {
    this.superProcessInstanceId = superProcessInstanceId;
    return this;
  }

   /**
   * Get superProcessInstanceId
   * @return superProcessInstanceId
  **/
  @ApiModelProperty(example = "3", value = "")
  public String getSuperProcessInstanceId() {
    return superProcessInstanceId;
  }

  public void setSuperProcessInstanceId(String superProcessInstanceId) {
    this.superProcessInstanceId = superProcessInstanceId;
  }

  public HistoricProcessInstanceResponse variables(List<RestVariable> variables) {
    this.variables = variables;
    return this;
  }

  public HistoricProcessInstanceResponse addVariablesItem(RestVariable variablesItem) {
    if (this.variables == null) {
      this.variables = new ArrayList<RestVariable>();
    }
    this.variables.add(variablesItem);
    return this;
  }

   /**
   * Get variables
   * @return variables
  **/
  @ApiModelProperty(value = "")
  public List<RestVariable> getVariables() {
    return variables;
  }

  public void setVariables(List<RestVariable> variables) {
    this.variables = variables;
  }

  public HistoricProcessInstanceResponse callbackId(String callbackId) {
    this.callbackId = callbackId;
    return this;
  }

   /**
   * Get callbackId
   * @return callbackId
  **/
  @ApiModelProperty(example = "3", value = "")
  public String getCallbackId() {
    return callbackId;
  }

  public void setCallbackId(String callbackId) {
    this.callbackId = callbackId;
  }

  public HistoricProcessInstanceResponse callbackType(String callbackType) {
    this.callbackType = callbackType;
    return this;
  }

   /**
   * Get callbackType
   * @return callbackType
  **/
  @ApiModelProperty(example = "cmmn", value = "")
  public String getCallbackType() {
    return callbackType;
  }

  public void setCallbackType(String callbackType) {
    this.callbackType = callbackType;
  }

  public HistoricProcessInstanceResponse referenceId(String referenceId) {
    this.referenceId = referenceId;
    return this;
  }

   /**
   * Get referenceId
   * @return referenceId
  **/
  @ApiModelProperty(example = "123", value = "")
  public String getReferenceId() {
    return referenceId;
  }

  public void setReferenceId(String referenceId) {
    this.referenceId = referenceId;
  }

  public HistoricProcessInstanceResponse referenceType(String referenceType) {
    this.referenceType = referenceType;
    return this;
  }

   /**
   * Get referenceType
   * @return referenceType
  **/
  @ApiModelProperty(example = "event-to-bpmn-2.0-process", value = "")
  public String getReferenceType() {
    return referenceType;
  }

  public void setReferenceType(String referenceType) {
    this.referenceType = referenceType;
  }

  public HistoricProcessInstanceResponse tenantId(String tenantId) {
    this.tenantId = tenantId;
    return this;
  }

   /**
   * Get tenantId
   * @return tenantId
  **/
  @ApiModelProperty(example = "someTenantId", value = "")
  public String getTenantId() {
    return tenantId;
  }

  public void setTenantId(String tenantId) {
    this.tenantId = tenantId;
  }


  @Override
  public boolean equals(java.lang.Object o) {
    if (this == o) {
      return true;
    }
    if (o == null || getClass() != o.getClass()) {
      return false;
    }
    HistoricProcessInstanceResponse historicProcessInstanceResponse = (HistoricProcessInstanceResponse) o;
    return Objects.equals(this.id, historicProcessInstanceResponse.id) &&
        Objects.equals(this.url, historicProcessInstanceResponse.url) &&
        Objects.equals(this.name, historicProcessInstanceResponse.name) &&
        Objects.equals(this.businessKey, historicProcessInstanceResponse.businessKey) &&
        Objects.equals(this.processDefinitionId, historicProcessInstanceResponse.processDefinitionId) &&
        Objects.equals(this.processDefinitionUrl, historicProcessInstanceResponse.processDefinitionUrl) &&
        Objects.equals(this.processDefinitionName, historicProcessInstanceResponse.processDefinitionName) &&
        Objects.equals(this.processDefinitionDescription, historicProcessInstanceResponse.processDefinitionDescription) &&
        Objects.equals(this.startTime, historicProcessInstanceResponse.startTime) &&
        Objects.equals(this.endTime, historicProcessInstanceResponse.endTime) &&
        Objects.equals(this.durationInMillis, historicProcessInstanceResponse.durationInMillis) &&
        Objects.equals(this.startUserId, historicProcessInstanceResponse.startUserId) &&
        Objects.equals(this.startActivityId, historicProcessInstanceResponse.startActivityId) &&
        Objects.equals(this.endActivityId, historicProcessInstanceResponse.endActivityId) &&
        Objects.equals(this.deleteReason, historicProcessInstanceResponse.deleteReason) &&
        Objects.equals(this.superProcessInstanceId, historicProcessInstanceResponse.superProcessInstanceId) &&
        Objects.equals(this.variables, historicProcessInstanceResponse.variables) &&
        Objects.equals(this.callbackId, historicProcessInstanceResponse.callbackId) &&
        Objects.equals(this.callbackType, historicProcessInstanceResponse.callbackType) &&
        Objects.equals(this.referenceId, historicProcessInstanceResponse.referenceId) &&
        Objects.equals(this.referenceType, historicProcessInstanceResponse.referenceType) &&
        Objects.equals(this.tenantId, historicProcessInstanceResponse.tenantId);
  }

  @Override
  public int hashCode() {
    return Objects.hash(id, url, name, businessKey, processDefinitionId, processDefinitionUrl, processDefinitionName, processDefinitionDescription, startTime, endTime, durationInMillis, startUserId, startActivityId, endActivityId, deleteReason, superProcessInstanceId, variables, callbackId, callbackType, referenceId, referenceType, tenantId);
  }


  @Override
  public String toString() {
    StringBuilder sb = new StringBuilder();
    sb.append("class HistoricProcessInstanceResponse {\n");

    sb.append("    id: ").append(toIndentedString(id)).append("\n");
    sb.append("    url: ").append(toIndentedString(url)).append("\n");
    sb.append("    name: ").append(toIndentedString(name)).append("\n");
    sb.append("    businessKey: ").append(toIndentedString(businessKey)).append("\n");
    sb.append("    processDefinitionId: ").append(toIndentedString(processDefinitionId)).append("\n");
    sb.append("    processDefinitionUrl: ").append(toIndentedString(processDefinitionUrl)).append("\n");
    sb.append("    processDefinitionName: ").append(toIndentedString(processDefinitionName)).append("\n");
    sb.append("    processDefinitionDescription: ").append(toIndentedString(processDefinitionDescription)).append("\n");
    sb.append("    startTime: ").append(toIndentedString(startTime)).append("\n");
    sb.append("    endTime: ").append(toIndentedString(endTime)).append("\n");
    sb.append("    durationInMillis: ").append(toIndentedString(durationInMillis)).append("\n");
    sb.append("    startUserId: ").append(toIndentedString(startUserId)).append("\n");
    sb.append("    startActivityId: ").append(toIndentedString(startActivityId)).append("\n");
    sb.append("    endActivityId: ").append(toIndentedString(endActivityId)).append("\n");
    sb.append("    deleteReason: ").append(toIndentedString(deleteReason)).append("\n");
    sb.append("    superProcessInstanceId: ").append(toIndentedString(superProcessInstanceId)).append("\n");
    sb.append("    variables: ").append(toIndentedString(variables)).append("\n");
    sb.append("    callbackId: ").append(toIndentedString(callbackId)).append("\n");
    sb.append("    callbackType: ").append(toIndentedString(callbackType)).append("\n");
    sb.append("    referenceId: ").append(toIndentedString(referenceId)).append("\n");
    sb.append("    referenceType: ").append(toIndentedString(referenceType)).append("\n");
    sb.append("    tenantId: ").append(toIndentedString(tenantId)).append("\n");
    sb.append("}");
    return sb.toString();
  }

  /**
   * Convert the given object to string with each line indented by 4 spaces
   * (except the first line).
   */
  private String toIndentedString(java.lang.Object o) {
    if (o == null) {
      return "null";
    }
    return o.toString().replace("\n", "\n    ");
  }

}
